<?php

use think\migration\Seeder;

class InitSetting extends Seeder
{
    /**
     * Run Method.
     *
     * Write your database seeder using this method.
     *
     * More information on writing seeders is available here:
     * http://docs.phinx.org/en/latest/seeding.html
     */
    public function run()
    {
        $data = [
            'web_name' => '',
            'web_domain' => '',
            'web_icp' => '',
            'seo_keywords' => '',
            'seo_description' => '',
        ];
        $setting = $this->table('settings');
        foreach ($data as $k => $v) {
            $setting->insert([
                'c_name' => $k,
                'c_value' => $v,
            ])->save();

        }
    }
}